package greate.project.mysql;

import org.apache.camel.builder.RouteBuilder;

/**
 * @author v_zhangshun01
 */
public class LogRouter extends RouteBuilder {

    private String from;

    private String to;

    public LogRouter(String from, String to) {
        this.from = from;
        this.to = to;
    }


    @Override
    public void configure() throws Exception {
        from("direct:" + from)
                .log("${body}")
                .to("direct:" + to);
    }

}
